#open firewalld and add a port of ssh
#!/bin/sh
#read port of ssh
pors=`grep ^Port /etc/ssh/sshd_config | awk '{print $2}'`
echo "Your ssh port is $pors"
service firewalld start
firewall-cmd --add-port=$[pors]/tcp --permanent
firewall-cmd --reload
